<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<link rel="Bookmark" href="/favicon.ico" >
<link rel="Shortcut Icon" href="/favicon.ico" />
<link rel="stylesheet" type="text/css" href="static/h-ui/css/H-ui.min.css" />
<link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/H-ui.admin.css" />
<link rel="stylesheet" type="text/css" href="lib/Hui-iconfont/1.0.8/iconfont.css" />
<link rel="stylesheet" type="text/css" href="static/h-ui.admin/skin/default/skin.css" id="skin" />
<link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/style.css" />
<script src="./lib/vue.min.js"></script>
<script src="./lib/params.js"></script>
<link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
<script src="https://unpkg.com/element-ui/lib/index.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/axios/0.24.0/axios.js"></script>
<script src="./lib/token.js"></script>
<title>erp</title>
</head>
<body>
<div id="app">
	<header class="navbar-wrapper">
		<div class="navbar navbar-fixed-top">
			<div class="container-fluid cl">
				<a aria-hidden="false" class="nav-toggle Hui-iconfont visible-xs" href="javascript:;">&#xe667;</a>
				<nav class="nav navbar-nav">
					<ul class="cl">
						<li class="dropDown dropDown_hover"><a href="javascript:;" class="dropDown_A"></a>
							<ul class="dropDown-menu menu radius box-shadow">
						</ul>
					</li>
				</ul>
			</nav>
			<nav id="Hui-userbar" class="nav navbar-nav navbar-userbar hidden-xs">
				<ul class="cl">
					<li>erp</li>
					<li class="dropDown dropDown_hover">
						<a href="#" class="dropDown_A">{{user.uname}}<i class="Hui-iconfont">&#xe6d5;</i></a>
						<ul class="dropDown-menu menu radius box-shadow">
							<li><a href="javascript:;" @click="myselfinfo">个人信息</a></li>
							<li><a href="login.html" @click="closeSession()">切换账户</a></li>
							<li><a href="login.html" @click="closeSession()">退出</a></li>
					</ul>
				</li>
					<li id="Hui-skin" class="dropDown right dropDown_hover"> <a href="javascript:;" class="dropDown_A" title="换肤"><i class="Hui-iconfont" style="font-size:18px">&#xe62a;</i></a>
						<ul class="dropDown-menu menu radius box-shadow">
							<li><a href="javascript:;" data-val="default" title="默认（黑色）">默认（黑色）</a></li>
							<li><a href="javascript:;" data-val="blue" title="蓝色">蓝色</a></li>
							<li><a href="javascript:;" data-val="green" title="绿色">绿色</a></li>
							<li><a href="javascript:;" data-val="red" title="红色">红色</a></li>
							<li><a href="javascript:;" data-val="yellow" title="黄色">黄色</a></li>
							<li><a href="javascript:;" data-val="orange" title="橙色">橙色</a></li>
						</ul>
					</li>
				</ul>
			</nav>
		</div>
	</div>
	</header>

	<el-dialog title="员工信息" :visible.sync="descriptionsVisible">
	<el-descriptions title="用户信息" >
		<el-descriptions-item label="真实名">{{person.perRealname}}</el-descriptions-item>
		<el-descriptions-item label="用户名">{{person.perUsername}}</el-descriptions-item>
		<el-descriptions-item label="编号">{{person.perIdnumber}}</el-descriptions-item>
		<el-descriptions-item label="联系方式">{{person.perTelephone}}</el-descriptions-item>
		<el-descriptions-item label="家庭住址">{{person.perAddress}}</el-descriptions-item>
		<el-descriptions-item label="出生日期">{{person.perBirthday}}</el-descriptions-item>
		<el-descriptions-item label="电子邮箱">{{person.perEmail}}</el-descriptions-item>
		<el-descriptions-item label="备注">
		  <el-tag size="small">{{person.perMessage}}</el-tag>
		</el-descriptions-item>
	</el-descriptions>
    </el-dialog>

	<aside class="Hui-aside">
        <el-row class="tac">
            <el-col class="menu_dropdown bk_2">
                <el-menu>
                    <el-submenu v-for="power in powers" v-if="power.purl == null || power.purl == ''">
                        <template slot="title">
                            <i class="Hui-iconfont">&#xe616;</i>{{power.pname}}
                        </template>
                        <el-menu-item v-for="(p,index) in powers" v-if="p.purl != null && p.ppid == power.pid">
                            <a @click="unique(index)" v-bind:data-href="p.purl" v-bind:data-title="p.pname" href="javascript:void(0)">{{p.pname}}</a>
                        </el-menu-item>
                    </el-submenu>
                </el-menu>
            </el-col>
        </el-row>
	</aside>
	<div class="dislpayArrow hidden-xs"><a class="pngfix" href="javascript:void(0);" onClick="displaynavbar(this)"></a></div>
	
    <section class="Hui-article-box">
        <div id="Hui-tabNav" class="Hui-tabNav hidden-xs">
            <div class="Hui-tabNav-wp">
                <ul id="min_title_list" class="acrossTab cl"></ul>
            </div>
            <div class="Hui-tabNav-more btn-group"><a id="js-tabNav-prev" class="btn radius btn-default size-S" href="javascript:;"><i class="Hui-iconfont">&#xe6d4;</i></a><a id="js-tabNav-next" class="btn radius btn-default size-S" href="javascript:;"><i class="Hui-iconfont">&#xe6d7;</i></a></div>
        </div>
        <div id="iframe_box" class="Hui-article">
            <div class="show_iframe">
               <div style="display:none" class="loading"></div>
            </div>
        </div>
    </section>
	
	<div class="contextMenu" id="Huiadminmenu">
		<ul>
			<li id="closethis">关闭当前</li>
			<li id="closeall">关闭全部</li>
	    </ul>
	</div>
</div>
<!--_footer 作为公共模版分离出去-->
<script type="text/javascript" src="lib/jquery/1.9.1/jquery.min.js"></script> 
<script type="text/javascript" src="lib/layer/2.4/layer.js"></script>
<script type="text/javascript" src="static/h-ui/js/H-ui.min.js"></script>
<script type="text/javascript" src="static/h-ui.admin/js/H-ui.admin.js"></script> 
<!--/_footer 作为公共模版分离出去-->
<script>
	new Vue({
		el:"#app",
		data:{
			descriptionsVisible:false,
            person:{},
            powers:[{}],
            index:"",
            subform: {
                perUsername: 'ZH',
                perPassword: "123456",
            },
            flag: true,
            message: "",
			user:{
				uid:''
			}
		},
		created(){
			this.user = JSON.parse(sessionStorage.getItem("user")) 
			if(this.user == null){
				location.href = "login.html"
			}
            this.getAll(); 
		},
		methods:{
            getAll(){
                    axios.get(`http://localhost:8001/power/returnOnePowerListTree/${this.user.uid}`)
                    .then(response=>{
                        this.powers = response.data.data;
                    })
            },
            unique(i){
                    this.index = i
            },
			myselfinfo(){
				this.descriptionsVisible=true;
			}
		}
	})
</script>
</body>
</html>